package com.itheima.wisdomnext.entity;

import java.sql.Timestamp;
import java.util.List;

public class Topic {
    private Integer id;          // 话题 ID
    private String name;         // 话题名称
    private String description;  // 话题描述
    private Integer createdBy;   // 创建者 ID
    private Timestamp createdAt; // 创建时间
    private Integer isOfficial;  // 是否官方话题（0=否，1=是）
    private List<Postshow> posts; // 话题下的帖子列表


    // Getters 和 Setters
    public Integer getId() { return id; }
    public void setId(Integer id) { this.id = id; }

    public String getName() { return name; }
    public void setName(String name) { this.name = name; }

    public String getDescription() { return description; }
    public void setDescription(String description) { this.description = description; }

    public Integer getCreatedBy() { return createdBy; }
    public void setCreatedBy(Integer createdBy) { this.createdBy = createdBy; }

    public Timestamp getCreatedAt() { return createdAt; }
    public void setCreatedAt(Timestamp createdAt) { this.createdAt = createdAt; }

    public Integer getIsOfficial() { return isOfficial; }
    public void setIsOfficial(Integer isOfficial) { this.isOfficial = isOfficial; }

    public List<Postshow> getPosts() {
        return posts;
    }

    public void setPosts(List<Postshow> posts) {
        this.posts = posts;
    }
}
